﻿<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ include file="/static/include/top.jsp"%>
<%@page import="cn.com.generaldata.os.common.Constants" %>
<%
String urlm = Constants.METHOD_SHOW_CREATE_REPORT;
String urlr = Constants.REPORT_OPERATOR_ID;
String urlc = Constants.REPORT_PROXY_ID;
String urlp = Constants.REPORT_TYPE_ID;
%>
<script>document.title="待填报列表";</script>
<script type="text/javascript">
function openViewWin(url,tit){
	openWin(tit,url,1000,500);
}
</script>
   <table>
	<tbody>
		<tr>
			<th><img src="${ctx}/static/images/pages/cen/rig/ico_01.png"
				align="absmiddle">&nbsp;待填报</th>
		</tr>
	</tbody>
  </table>
  <br />
	<c:if test="${empty obj}">
		<b>没有符合条件的记录。</b>
	</c:if>
<c:if test="${not empty obj}">
  <table id="listTable">
  <tbody>
    <tr>
        <th width="75%">待填报报表</th>
		<th width="25%">操作</th>
    </tr>
    <c:forEach var="oneRow" items="${obj}">
    		
    <tr>
      	<td align="left">${oneRow.reportDomainName}</td>
		<td align="left">
			<c:choose>
					<c:when test="${oneRow.status==1}"><a href="#" class="tab_text01" onclick="openReportWin('${oneRow.userId}','${oneRow.reportTypeId}','${oneRow.reportTimetype}','${oneRow.reportUnitIndustry}','${oneRow.reportYearTime}','${oneRow.reportQuarter}','${oneRow.reportMonth}','${oneRow.status}');return false;">填报</a></c:when>
					<c:when test="${oneRow.status==2}"><a href="#" class="tab_text01" onclick="openReportWin('${oneRow.userId}','${oneRow.reportTypeId}','${oneRow.reportTimetype}','${oneRow.reportUnitIndustry}','${oneRow.reportYearTime}','${oneRow.reportQuarter}','${oneRow.reportMonth}','${oneRow.status}');return false;">迟报</a></c:when>
					<c:when test="${oneRow.status==3}"><a href="#" class="tab_text01" onclick="openEditWin('${oneRow.id}');return false;">修改</a></c:when>
					<c:when test="${oneRow.status==4}"><a href="#" class="tab_text01" onclick="openViewWin('${oneRow.id}');return false;">查看</a></c:when>
						</c:choose>
		</td>
    </tr>
    </c:forEach>
    </tbody>
  </table>
  <script>
//查看
	function openViewWin(id){
		var url="${ctx}/reports/service.do?method=showReportInfo&reportOperatorId=${user.id}&reportId="+id;
		openWin("查看报表",url,null,550);
	}
	
	//填报
	function openReportWin(userId,reportTypeId,reportTimetype,reportUnitIndustry,reportYearTime,reportQuarter,reportMonth,status){
		var url="${ctx}/reports/service.do?method=showCreateReport&reportOperatorId="+userId+"&reportProxyId=${user.id}&reportTypeId="+reportTypeId+
		"&timeType=" + reportTimetype + "&unitIndustryId=" + reportUnitIndustry + "&yearType=" + reportYearTime + "&quarterDate=" +
		reportQuarter + "&reportVersion=" + 1 + "&timeDate=" + reportMonth+"&status="+status;
		openWin("报表填报",url,null,550,reSubmit);
	}

	//修改
	function openEditWin(id){
		var url="${ctx}/reports/service.do?method=showReportUpdate&reportOperatorId=${user.id}&reportId="+id;
		openWin("修改报表",url,null,550,reSubmit);
	}
	//重新提交表单
	function reSubmit(){
		location.reload(true);
	}
  </script>
</c:if>

<%@ include file="/static/include/bottom.jsp"%>
